3.28 \(\int \frac{A+B x+C x^2}{x^3 \left (a+b x^2+c x^4\right )} \, dx\)

Optimal. Leaf size=288 \[ -\frac{\left (A \left (b^2-2 a c\right )-a b C\right ) \tanh ^{-1}\left (\frac{b+2 c x^2}{\sqrt{b^2-4 a c}}\right )}{2 a^2 \sqrt{b^2-4 a c}}+\frac{(A b-a C) \log \left (a+b x^2+c x^4\right )}{4 a^2}-\frac{\log (x) (A b-a C)}{a^2}-\frac{A}{2 a x^2}-\frac{B \sqrt{c} \left (\frac{b}{\sqrt{b^2-4 a c}}+1\right ) \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x}{\sqrt{b-\sqrt{b^2-4 a c}}}\right )}{\sqrt{2} a \sqrt{b-\sqrt{b^2-4 a c}}}-\frac{B \sqrt{c} \left (1-\frac{b}{\sqrt{b^2-4 a c}}\right ) \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x}{\sqrt{\sqrt{b^2-4 a c}+b}}\right )}{\sqrt{2} a \sqrt{\sqrt{b^2-4 a c}+b}}-\frac{B}{a x} \]

[Out]

-A/(2*a*x^2) - B/(a*x) - (B*Sqrt[c]*(1 + b/Sqrt[b^2 - 4*a*c])*ArcTan[(Sqrt[2]*Sq
rt[c]*x)/Sqrt[b - Sqrt[b^2 - 4*a*c]]])/(Sqrt[2]*a*Sqrt[b - Sqrt[b^2 - 4*a*c]]) -
 (B*Sqrt[c]*(1 - b/Sqrt[b^2 - 4*a*c])*ArcTan[(Sqrt[2]*Sqrt[c]*x)/Sqrt[b + Sqrt[b
^2 - 4*a*c]]])/(Sqrt[2]*a*Sqrt[b + Sqrt[b^2 - 4*a*c]]) - ((A*(b^2 - 2*a*c) - a*b
*C)*ArcTanh[(b + 2*c*x^2)/Sqrt[b^2 - 4*a*c]])/(2*a^2*Sqrt[b^2 - 4*a*c]) - ((A*b
- a*C)*Log[x])/a^2 + ((A*b - a*C)*Log[a + b*x^2 + c*x^4])/(4*a^2)

_______________________________________________________________________________________

Rubi [A]  time = 1.10163, antiderivative size = 288, normalized size of antiderivative = 1., number of steps used = 13, number of rules used = 11, integrand size = 28, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.393 \[ -\frac{\left (A \left (b^2-2 a c\right )-a b C\right ) \tanh ^{-1}\left (\frac{b+2 c x^2}{\sqrt{b^2-4 a c}}\right )}{2 a^2 \sqrt{b^2-4 a c}}+\frac{(A b-a C) \log \left (a+b x^2+c x^4\right )}{4 a^2}-\frac{\log (x) (A b-a C)}{a^2}-\frac{A}{2 a x^2}-\frac{B \sqrt{c} \left (\frac{b}{\sqrt{b^2-4 a c}}+1\right ) \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x}{\sqrt{b-\sqrt{b^2-4 a c}}}\right )}{\sqrt{2} a \sqrt{b-\sqrt{b^2-4 a c}}}-\frac{B \sqrt{c} \left (1-\frac{b}{\sqrt{b^2-4 a c}}\right ) \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x}{\sqrt{\sqrt{b^2-4 a c}+b}}\right )}{\sqrt{2} a \sqrt{\sqrt{b^2-4 a c}+b}}-\frac{B}{a x} \]

Antiderivative was successfully verified.

[In]  Int[(A + B*x + C*x^2)/(x^3*(a + b*x^2 + c*x^4)),x]

[Out]

-A/(2*a*x^2) - B/(a*x) - (B*Sqrt[c]*(1 + b/Sqrt[b^2 - 4*a*c])*ArcTan[(Sqrt[2]*Sq
rt[c]*x)/Sqrt[b - Sqrt[b^2 - 4*a*c]]])/(Sqrt[2]*a*Sqrt[b - Sqrt[b^2 - 4*a*c]]) -
 (B*Sqrt[c]*(1 - b/Sqrt[b^2 - 4*a*c])*ArcTan[(Sqrt[2]*Sqrt[c]*x)/Sqrt[b + Sqrt[b
^2 - 4*a*c]]])/(Sqrt[2]*a*Sqrt[b + Sqrt[b^2 - 4*a*c]]) - ((A*(b^2 - 2*a*c) - a*b
*C)*ArcTanh[(b + 2*c*x^2)/Sqrt[b^2 - 4*a*c]])/(2*a^2*Sqrt[b^2 - 4*a*c]) - ((A*b
- a*C)*Log[x])/a^2 + ((A*b - a*C)*Log[a + b*x^2 + c*x^4])/(4*a^2)

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 117.703, size = 287, normalized size = 1. \[ - \frac{A}{2 a x^{2}} + \frac{\sqrt{2} B \sqrt{c} \left (b - \sqrt{- 4 a c + b^{2}}\right ) \operatorname{atan}{\left (\frac{\sqrt{2} \sqrt{c} x}{\sqrt{b + \sqrt{- 4 a c + b^{2}}}} \right )}}{2 a \sqrt{b + \sqrt{- 4 a c + b^{2}}} \sqrt{- 4 a c + b^{2}}} - \frac{\sqrt{2} B \sqrt{c} \left (b + \sqrt{- 4 a c + b^{2}}\right ) \operatorname{atan}{\left (\frac{\sqrt{2} \sqrt{c} x}{\sqrt{b - \sqrt{- 4 a c + b^{2}}}} \right )}}{2 a \sqrt{b - \sqrt{- 4 a c + b^{2}}} \sqrt{- 4 a c + b^{2}}} - \frac{B}{a x} - \frac{\left (A b - C a\right ) \log{\left (x^{2} \right )}}{2 a^{2}} + \frac{\left (A b - C a\right ) \log{\left (a + b x^{2} + c x^{4} \right )}}{4 a^{2}} - \frac{\left (- 2 A a c + A b^{2} - C a b\right ) \operatorname{atanh}{\left (\frac{b + 2 c x^{2}}{\sqrt{- 4 a c + b^{2}}} \right )}}{2 a^{2} \sqrt{- 4 a c + b^{2}}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate((C*x**2+B*x+A)/x**3/(c*x**4+b*x**2+a),x)

[Out]

-A/(2*a*x**2) + sqrt(2)*B*sqrt(c)*(b - sqrt(-4*a*c + b**2))*atan(sqrt(2)*sqrt(c)
*x/sqrt(b + sqrt(-4*a*c + b**2)))/(2*a*sqrt(b + sqrt(-4*a*c + b**2))*sqrt(-4*a*c
 + b**2)) - sqrt(2)*B*sqrt(c)*(b + sqrt(-4*a*c + b**2))*atan(sqrt(2)*sqrt(c)*x/s
qrt(b - sqrt(-4*a*c + b**2)))/(2*a*sqrt(b - sqrt(-4*a*c + b**2))*sqrt(-4*a*c + b
**2)) - B/(a*x) - (A*b - C*a)*log(x**2)/(2*a**2) + (A*b - C*a)*log(a + b*x**2 +
c*x**4)/(4*a**2) - (-2*A*a*c + A*b**2 - C*a*b)*atanh((b + 2*c*x**2)/sqrt(-4*a*c
+ b**2))/(2*a**2*sqrt(-4*a*c + b**2))

_______________________________________________________________________________________

Mathematica [A]  time = 1.95423, size = 377, normalized size = 1.31 \[ \frac{\frac{\left (A \left (b \sqrt{b^2-4 a c}-2 a c+b^2\right )-a C \left (\sqrt{b^2-4 a c}+b\right )\right ) \log \left (\sqrt{b^2-4 a c}-b-2 c x^2\right )}{\sqrt{b^2-4 a c}}+\frac{\left (A \left (b \sqrt{b^2-4 a c}+2 a c-b^2\right )+a C \left (b-\sqrt{b^2-4 a c}\right )\right ) \log \left (\sqrt{b^2-4 a c}+b+2 c x^2\right )}{\sqrt{b^2-4 a c}}+4 \log (x) (a C-A b)-\frac{2 a A}{x^2}-\frac{2 \sqrt{2} a B \sqrt{c} \left (\sqrt{b^2-4 a c}+b\right ) \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x}{\sqrt{b-\sqrt{b^2-4 a c}}}\right )}{\sqrt{b^2-4 a c} \sqrt{b-\sqrt{b^2-4 a c}}}-\frac{2 \sqrt{2} a B \sqrt{c} \left (\sqrt{b^2-4 a c}-b\right ) \tan ^{-1}\left (\frac{\sqrt{2} \sqrt{c} x}{\sqrt{\sqrt{b^2-4 a c}+b}}\right )}{\sqrt{b^2-4 a c} \sqrt{\sqrt{b^2-4 a c}+b}}-\frac{4 a B}{x}}{4 a^2} \]

Antiderivative was successfully verified.

[In]  Integrate[(A + B*x + C*x^2)/(x^3*(a + b*x^2 + c*x^4)),x]

[Out]

((-2*a*A)/x^2 - (4*a*B)/x - (2*Sqrt[2]*a*B*Sqrt[c]*(b + Sqrt[b^2 - 4*a*c])*ArcTa
n[(Sqrt[2]*Sqrt[c]*x)/Sqrt[b - Sqrt[b^2 - 4*a*c]]])/(Sqrt[b^2 - 4*a*c]*Sqrt[b -
Sqrt[b^2 - 4*a*c]]) - (2*Sqrt[2]*a*B*Sqrt[c]*(-b + Sqrt[b^2 - 4*a*c])*ArcTan[(Sq
rt[2]*Sqrt[c]*x)/Sqrt[b + Sqrt[b^2 - 4*a*c]]])/(Sqrt[b^2 - 4*a*c]*Sqrt[b + Sqrt[
b^2 - 4*a*c]]) + 4*(-(A*b) + a*C)*Log[x] + ((A*(b^2 - 2*a*c + b*Sqrt[b^2 - 4*a*c
]) - a*(b + Sqrt[b^2 - 4*a*c])*C)*Log[-b + Sqrt[b^2 - 4*a*c] - 2*c*x^2])/Sqrt[b^
2 - 4*a*c] + ((A*(-b^2 + 2*a*c + b*Sqrt[b^2 - 4*a*c]) + a*(b - Sqrt[b^2 - 4*a*c]
)*C)*Log[b + Sqrt[b^2 - 4*a*c] + 2*c*x^2])/Sqrt[b^2 - 4*a*c])/(4*a^2)

_______________________________________________________________________________________

Maple [B]  time = 0.057, size = 1054, normalized size = 3.7 \[ \text{result too large to display} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int((C*x^2+B*x+A)/x^3/(c*x^4+b*x^2+a),x)

[Out]

8*c/a/(32*a*c-8*b^2)*ln(2*c*x^2+(-4*a*c+b^2)^(1/2)+b)*A*b-2/a^2/(32*a*c-8*b^2)*l
n(2*c*x^2+(-4*a*c+b^2)^(1/2)+b)*A*b^3-4*c/a/(32*a*c-8*b^2)*ln(2*c*x^2+(-4*a*c+b^
2)^(1/2)+b)*A*(-4*a*c+b^2)^(1/2)+2/a^2/(32*a*c-8*b^2)*ln(2*c*x^2+(-4*a*c+b^2)^(1
/2)+b)*A*(-4*a*c+b^2)^(1/2)*b^2-2/a/(32*a*c-8*b^2)*ln(2*c*x^2+(-4*a*c+b^2)^(1/2)
+b)*C*b*(-4*a*c+b^2)^(1/2)-8*c/(32*a*c-8*b^2)*ln(2*c*x^2+(-4*a*c+b^2)^(1/2)+b)*C
+2/a/(32*a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*2^(1/2)/((-b+(-4*a*c+b^2)^(1/2))*c)^(1/2)*arctanh(c*x
*2^(1/2)/((-b+(-4*a*c+b^2)^(1/2))*c)^(1/2))-4*c/a/(32*a*c-8*b^2)*B*2^(1/2)/((-b+
(-4*a*c+b^2)^(1/2))*c)^(1/2)*arctanh(c*x*2^(1/2)/((-b+(-4*a*c+b^2)^(1/2))*c)^(1/
2))*b^2-B/a/x-1/2*A/a/x^2-1/a^2*ln(x)*A*b+1/a*ln(x)*C

_______________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \[ \frac{{\left (C a - A b\right )} \log \left (x\right )}{a^{2}} + \frac{-\int \frac{B a c x^{2} +{\left (C a - A b\right )} c x^{3} + B a b +{\left (C a b - A b^{2} + A a c\right )} x}{c x^{4} + b x^{2} + a}\,{d x}}{a^{2}} - \frac{2 \, B x + A}{2 \, a x^{2}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((C*x^2 + B*x + A)/((c*x^4 + b*x^2 + a)*x^3),x, algorithm="maxima")

[Out]

(C*a - A*b)*log(x)/a^2 + integrate(-(B*a*c*x^2 + (C*a - A*b)*c*x^3 + B*a*b + (C*
a*b - A*b^2 + A*a*c)*x)/(c*x^4 + b*x^2 + a), x)/a^2 - 1/2*(2*B*x + A)/(a*x^2)

_______________________________________________________________________________________

Fricas [F(-1)]  time = 0., size = 0, normalized size = 0. \[ \text{Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((C*x^2 + B*x + A)/((c*x^4 + b*x^2 + a)*x^3),x, algorithm="fricas")

[Out]

Timed out

_______________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \[ \text{Timed out} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((C*x**2+B*x+A)/x**3/(c*x**4+b*x**2+a),x)

[Out]

Timed out

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 1.29313, size = 1, normalized size = 0. \[ \mathit{Done} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((C*x^2 + B*x + A)/((c*x^4 + b*x^2 + a)*x^3),x, algorithm="giac")

[Out]

Done